/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package Entity;

import java.util.Date;
import java.util.List;
import javax.persistence.*;
/**
 *
 * @author USUARIO
 */
@Entity
@DiscriminatorValue("veterinarian")
public class Veterinarian extends Person{
   
    private String focusOfPractice;
    private String specialities;
    private int salary;
    private String graduatedAt;
    
    @OneToMany(mappedBy = "veterinarian")
    private List<Appointment> appointments;
    
    public Veterinarian(){
        super();
    }
    
    public Veterinarian(int ssn, String name, String lastName, Date bDay, String bPlace){
        super(ssn, name, lastName, bDay, bPlace);
        this.focusOfPractice = null;
        this.specialities = null;
        this.salary = 0;
        this.graduatedAt = null;
        this.appointments = null;
    }
    
    public Veterinarian(int ssn, String name, String lastName, Date bDay, String bPlace, 
            String focusOfPractice, String specialities, int salary, String graduatedAt){
        super(ssn, name, lastName, bDay, bPlace);
        this.focusOfPractice = focusOfPractice;
        this.specialities = specialities;
        this.salary = salary;
        this.graduatedAt = graduatedAt;
        this.appointments = null;
    }

    /**
     * @return the focusOfPractice
     */
    public String getFocusOfPractice() {
        return focusOfPractice;
    }

    /**
     * @param focusOfPractice the focusOfPractice to set
     */
    public void setFocusOfPractice(String focusOfPractice) {
        this.focusOfPractice = focusOfPractice;
    }

    /**
     * @return the specialities
     */
    public String getSpecialities() {
        return specialities;
    }

    /**
     * @param specialities the specialities to set
     */
    public void setSpecialities(String specialities) {
        this.specialities = specialities;
    }

    /**
     * @return the salary
     */
    public int getSalary() {
        return salary;
    }

    /**
     * @param salary the salary to set
     */
    public void setSalary(int salary) {
        this.salary = salary;
    }

    /**
     * @return the graduatedAt
     */
    public String getGraduatedAt() {
        return graduatedAt;
    }

    /**
     * @param graduatedAt the graduatedAt to set
     */
    public void setGraduatedAt(String graduatedAt) {
        this.graduatedAt = graduatedAt;
    }

    /**
     * @return the appointments
     */
    public List<Appointment> getAppointments() {
        return appointments;
    }

    /**
     * @param appointments the appointments to set
     */
    public void setAppointments(List<Appointment> appointments) {
        this.appointments = appointments;
    }
}
